3.2.60 \(\int x (a+b \tanh ^{-1}(\frac {c}{x^2})) \, dx\) [160]

Optimal. Leaf size=34 \[ \frac {1}{2} x^2 \left (a+b \tanh ^{-1}\left (\frac {c}{x^2}\right )\right )+\frac {1}{4} b c \log \left (c^2-x^4\right ) \]

[Out]

1/2*x^2*(a+b*arctanh(c/x^2))+1/4*b*c*ln(-x^4+c^2)

________________________________________________________________________________________

Rubi [A]
time = 0.01, antiderivative size = 34, normalized size of antiderivative = 1.00, number of steps used = 3, number of rules used = 3, integrand size = 12, \(\frac {\text {number of rules}}{\text {integrand size}}\) = 0.250, Rules used = {6037, 269, 266} \begin {gather*} \frac {1}{2} x^2 \left (a+b \tanh ^{-1}\left (\frac {c}{x^2}\right )\right )+\frac {1}{4} b c \log \left (c^2-x^4\right ) \end {gather*}

Antiderivative was successfully verified.

[In]

Int[x*(a + b*ArcTanh[c/x^2]),x]

[Out]

(x^2*(a + b*ArcTanh[c/x^2]))/2 + (b*c*Log[c^2 - x^4])/4

Rule 266

Int[(x_)^(m_.)/((a_) + (b_.)*(x_)^(n_)), x_Symbol] :> Simp[Log[RemoveContent[a + b*x^n, x]]/(b*n), x] /; FreeQ
[{a, b, m, n}, x] && EqQ[m, n - 1]

Rule 269

Int[(x_)^(m_.)*((a_) + (b_.)*(x_)^(n_))^(p_), x_Symbol] :> Int[x^(m + n*p)*(b + a/x^n)^p, x] /; FreeQ[{a, b, m
, n}, x] && IntegerQ[p] && NegQ[n]

Rule 6037

Int[((a_.) + ArcTanh[(c_.)*(x_)^(n_.)]*(b_.))^(p_.)*(x_)^(m_.), x_Symbol] :> Simp[x^(m + 1)*((a + b*ArcTanh[c*
x^n])^p/(m + 1)), x] - Dist[b*c*n*(p/(m + 1)), Int[x^(m + n)*((a + b*ArcTanh[c*x^n])^(p - 1)/(1 - c^2*x^(2*n))
), x], x] /; FreeQ[{a, b, c, m, n}, x] && IGtQ[p, 0] && (EqQ[p, 1] || (EqQ[n, 1] && IntegerQ[m])) && NeQ[m, -1
]

Rubi steps

\begin {align*} \int x \left (a+b \tanh ^{-1}\left (\frac {c}{x^2}\right )\right ) \, dx &=\frac {1}{2} x^2 \left (a+b \tanh ^{-1}\left (\frac {c}{x^2}\right )\right )+(b c) \int \frac {1}{\left (1-\frac {c^2}{x^4}\right ) x} \, dx\\ &=\frac {1}{2} x^2 \left (a+b \tanh ^{-1}\left (\frac {c}{x^2}\right )\right )+(b c) \int \frac {x^3}{-c^2+x^4} \, dx\\ &=\frac {1}{2} x^2 \left (a+b \tanh ^{-1}\left (\frac {c}{x^2}\right )\right )+\frac {1}{4} b c \log \left (c^2-x^4\right )\\ \end {align*}

________________________________________________________________________________________

Mathematica [A]
time = 0.01, size = 39, normalized size = 1.15 \begin {gather*} \frac {a x^2}{2}+\frac {1}{2} b x^2 \tanh ^{-1}\left (\frac {c}{x^2}\right )+\frac {1}{4} b c \log \left (-c^2+x^4\right ) \end {gather*}

Antiderivative was successfully verified.

[In]

Integrate[x*(a + b*ArcTanh[c/x^2]),x]

[Out]

(a*x^2)/2 + (b*x^2*ArcTanh[c/x^2])/2 + (b*c*Log[-c^2 + x^4])/4

________________________________________________________________________________________

Maple [A]
time = 0.10, size = 52, normalized size = 1.53

method result size
derivativedivides \(\frac {a \,x^{2}}{2}+\frac {b \,x^{2} \arctanh \left (\frac {c}{x^{2}}\right )}{2}-b c \ln \left (\frac {1}{x}\right )+\frac {b c \ln \left (1+\frac {c}{x^{2}}\right )}{4}+\frac {b c \ln \left (\frac {c}{x^{2}}-1\right )}{4}\) \(52\)
default \(\frac {a \,x^{2}}{2}+\frac {b \,x^{2} \arctanh \left (\frac {c}{x^{2}}\right )}{2}-b c \ln \left (\frac {1}{x}\right )+\frac {b c \ln \left (1+\frac {c}{x^{2}}\right )}{4}+\frac {b c \ln \left (\frac {c}{x^{2}}-1\right )}{4}\) \(52\)
risch \(\frac {b \,x^{2} \ln \left (x^{2}+c \right )}{4}-\frac {b \,x^{2} \ln \left (-x^{2}+c \right )}{4}+\frac {i \pi b \,x^{2} \mathrm {csgn}\left (\frac {i}{x^{2}}\right ) \mathrm {csgn}\left (i \left (-x^{2}+c \right )\right ) \mathrm {csgn}\left (\frac {i \left (-x^{2}+c \right )}{x^{2}}\right )}{8}+\frac {i \pi b \,x^{2} \mathrm {csgn}\left (i \left (x^{2}+c \right )\right ) \mathrm {csgn}\left (\frac {i \left (x^{2}+c \right )}{x^{2}}\right )^{2}}{8}-\frac {i \pi b \,x^{2}}{4}-\frac {i \pi b \,x^{2} \mathrm {csgn}\left (\frac {i}{x^{2}}\right ) \mathrm {csgn}\left (\frac {i \left (-x^{2}+c \right )}{x^{2}}\right )^{2}}{8}-\frac {i \pi b \,x^{2} \mathrm {csgn}\left (\frac {i \left (-x^{2}+c \right )}{x^{2}}\right )^{3}}{8}-\frac {i \pi b \,x^{2} \mathrm {csgn}\left (\frac {i \left (x^{2}+c \right )}{x^{2}}\right )^{3}}{8}+\frac {i \pi b \,x^{2} \mathrm {csgn}\left (\frac {i}{x^{2}}\right ) \mathrm {csgn}\left (\frac {i \left (x^{2}+c \right )}{x^{2}}\right )^{2}}{8}+\frac {i \pi b \,x^{2} \mathrm {csgn}\left (\frac {i \left (-x^{2}+c \right )}{x^{2}}\right )^{2}}{4}-\frac {i \pi b \,x^{2} \mathrm {csgn}\left (\frac {i}{x^{2}}\right ) \mathrm {csgn}\left (i \left (x^{2}+c \right )\right ) \mathrm {csgn}\left (\frac {i \left (x^{2}+c \right )}{x^{2}}\right )}{8}-\frac {i \pi b \,x^{2} \mathrm {csgn}\left (i \left (-x^{2}+c \right )\right ) \mathrm {csgn}\left (\frac {i \left (-x^{2}+c \right )}{x^{2}}\right )^{2}}{8}+\frac {a \,x^{2}}{2}+\frac {b c \ln \left (x^{4}-c^{2}\right )}{4}\) \(328\)

Verification of antiderivative is not currently implemented for this CAS.

[In]

int(x*(a+b*arctanh(c/x^2)),x,method=_RETURNVERBOSE)

[Out]

1/2*a*x^2+1/2*b*x^2*arctanh(c/x^2)-b*c*ln(1/x)+1/4*b*c*ln(1+c/x^2)+1/4*b*c*ln(c/x^2-1)

________________________________________________________________________________________

Maxima [A]
time = 0.25, size = 34, normalized size = 1.00 \begin {gather*} \frac {1}{2} \, a x^{2} + \frac {1}{4} \, {\left (2 \, x^{2} \operatorname {artanh}\left (\frac {c}{x^{2}}\right ) + c \log \left (x^{4} - c^{2}\right )\right )} b \end {gather*}

Verification of antiderivative is not currently implemented for this CAS.

[In]

integrate(x*(a+b*arctanh(c/x^2)),x, algorithm="maxima")

[Out]

1/2*a*x^2 + 1/4*(2*x^2*arctanh(c/x^2) + c*log(x^4 - c^2))*b

________________________________________________________________________________________

Fricas [A]
time = 0.34, size = 43, normalized size = 1.26 \begin {gather*} \frac {1}{4} \, b x^{2} \log \left (\frac {x^{2} + c}{x^{2} - c}\right ) + \frac {1}{2} \, a x^{2} + \frac {1}{4} \, b c \log \left (x^{4} - c^{2}\right ) \end {gather*}

Verification of antiderivative is not currently implemented for this CAS.

[In]

integrate(x*(a+b*arctanh(c/x^2)),x, algorithm="fricas")

[Out]

1/4*b*x^2*log((x^2 + c)/(x^2 - c)) + 1/2*a*x^2 + 1/4*b*c*log(x^4 - c^2)

________________________________________________________________________________________

Sympy [B] Leaf count of result is larger than twice the leaf count of optimal. 61 vs. \(2 (27) = 54\).
time = 1.35, size = 61, normalized size = 1.79 \begin {gather*} \frac {a x^{2}}{2} + \frac {b c \log {\left (x - \sqrt {- c} \right )}}{2} + \frac {b c \log {\left (x + \sqrt {- c} \right )}}{2} - \frac {b c \operatorname {atanh}{\left (\frac {c}{x^{2}} \right )}}{2} + \frac {b x^{2} \operatorname {atanh}{\left (\frac {c}{x^{2}} \right )}}{2} \end {gather*}

Verification of antiderivative is not currently implemented for this CAS.

[In]

integrate(x*(a+b*atanh(c/x**2)),x)

[Out]

a*x**2/2 + b*c*log(x - sqrt(-c))/2 + b*c*log(x + sqrt(-c))/2 - b*c*atanh(c/x**2)/2 + b*x**2*atanh(c/x**2)/2

________________________________________________________________________________________

Giac [B] Leaf count of result is larger than twice the leaf count of optimal. 184 vs. \(2 (30) = 60\).
time = 0.43, size = 184, normalized size = 5.41 \begin {gather*} \frac {1}{2} \, a x^{2} + \frac {{\left (c^{2} {\left (\log \left (\frac {{\left | -x^{2} - c \right |}}{{\left | -x^{2} + c \right |}}\right ) - \log \left ({\left | \frac {x^{2} + c}{x^{2} - c} - 1 \right |}\right )\right )} + \frac {c^{2} \log \left (-\frac {\frac {c {\left (\frac {x^{2} + c}{{\left (x^{2} - c\right )} c} - \frac {1}{c}\right )}}{\frac {x^{2} + c}{x^{2} - c} + 1} + 1}{\frac {c {\left (\frac {x^{2} + c}{{\left (x^{2} - c\right )} c} - \frac {1}{c}\right )}}{\frac {x^{2} + c}{x^{2} - c} + 1} - 1}\right )}{\frac {x^{2} + c}{x^{2} - c} - 1}\right )} b}{2 \, c} \end {gather*}

Verification of antiderivative is not currently implemented for this CAS.

[In]

integrate(x*(a+b*arctanh(c/x^2)),x, algorithm="giac")

[Out]

1/2*a*x^2 + 1/2*(c^2*(log(abs(-x^2 - c)/abs(-x^2 + c)) - log(abs((x^2 + c)/(x^2 - c) - 1))) + c^2*log(-(c*((x^
2 + c)/((x^2 - c)*c) - 1/c)/((x^2 + c)/(x^2 - c) + 1) + 1)/(c*((x^2 + c)/((x^2 - c)*c) - 1/c)/((x^2 + c)/(x^2
- c) + 1) - 1))/((x^2 + c)/(x^2 - c) - 1))*b/c

________________________________________________________________________________________

Mupad [B]
time = 0.79, size = 47, normalized size = 1.38 \begin {gather*} \frac {a\,x^2}{2}+\frac {b\,x^2\,\ln \left (x^2+c\right )}{4}+\frac {b\,c\,\ln \left (x^4-c^2\right )}{4}-\frac {b\,x^2\,\ln \left (x^2-c\right )}{4} \end {gather*}

Verification of antiderivative is not currently implemented for this CAS.

[In]

int(x*(a + b*atanh(c/x^2)),x)

[Out]

(a*x^2)/2 + (b*x^2*log(c + x^2))/4 + (b*c*log(x^4 - c^2))/4 - (b*x^2*log(x^2 - c))/4

________________________________________________________________________________________